﻿Imports BusinessLogicLayer

Partial Class MantProveedores
    Inherits System.Web.UI.Page
    Dim errores As String


    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        'Instanciamos la clase 
        Dim capanegocios As New ProveedorBL

        Try
            gvProveedores.DataSource = capanegocios.ListarProveedores
            gvProveedores.DataBind()

        Catch ex As Exception

            errores = capanegocios.ChapaError
            'Redirigimos  a la página Errores.aspx para mostrar el error
            Response.Redirect("Errores.aspx?id=" & errores)

        Finally
            capanegocios = Nothing
        End Try
    End Sub
End Class
